package cn.edu.cqut.test5;

public class TestShape {
	public static void main(String[] args) {
		Shape shape = new Triangle(10, 5);
		show(shape);
//		System.out.println(getArea(shape));
		shape = new Square(20);
//		System.out.println(getArea(shape));
		show(shape);
	}
	
	public static double getArea(Shape obj)
	{
		return obj.getArea();
	}
	
	public static void show(Shape obj)
	{
		obj.show();
	}
}
